package com.ktjiaotu.examples;

import com.ktjiaotu.pojo.Person;

import java.lang.reflect.Method;

/**
 * @Author: DABINGCHNEGJIAO
 * @CreateTime: 2025-06-04
 * @Description:
 * @Version: 1.0
 */
public class MethodInfo {
    public static void main(String[] args) {
        Class pc = Person.class;
        try {
            Object o = pc.newInstance();

            Method silentMethod = pc.getDeclaredMethod("silentMethod");
            silentMethod.setAccessible(true);
            silentMethod.invoke(o);
            System.out.println(silentMethod);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
